package com.ztgf.order.mapper;

import com.baomidou.mybatisplus.plugins.Page;
import com.ztgf.order.models.bo.OrderCommissionStatisticsBO;
import com.ztgf.order.models.vo.OrderCommissionVO;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.math.BigDecimal;
import java.util.List;

/*
 * @author: chenyu.wang
 * @date: 2020-08-10
 * @description:后台管理系统佣金统计服务映射
 */
@Mapper
public interface OrderCommissionStatisticsMapper {

    /**
     * @description:佣金统计
     * @author: chenyu.wang
     * @date: 2020-08-10
     * @param:
     * @return:
     */
    BigDecimal queryCommissionStatistics(@Param("item") OrderCommissionStatisticsBO bo);

    /**
     * @description:查询类目
     * @author: chenyu.wang
     * @date: 2020-08-11
     * @param:
     * @return:
     */
    List<OrderCommissionVO> queryAllCategory(Page<OrderCommissionVO> page);

    /**
     * @description:根据类目id查询类目佣金
     * @author: chenyu.wang
     * @date: 2020-08-11
     * @param:
     * @return:
     */
    BigDecimal queryForVariousItems(@Param("item") OrderCommissionStatisticsBO bo);

    /**
     * @description:查询所有卖家店铺
     * @author: chenyu.wang
     * @date: 2020-08-11
     * @param:
     * @return:
     */
    List<OrderCommissionVO> queryAllShop(Page<OrderCommissionVO> page);

    /**
     * @description:各店铺佣金统计
     * @author: chenyu.wang
     * @date: 2020-08-11
     * @param:
     * @return:
     */
    BigDecimal queryShopCommission(@Param("shopId") Long shopId, @Param("item") OrderCommissionStatisticsBO bo);

    /**
     * @Description: 新的类目佣金统计
     * @Author: WangChenYu
     * @Param: [page, bo]
     * @Date: 2020-10-19 16:13
     */
    List<OrderCommissionVO> queryNew(Page<OrderCommissionVO> page, @Param("item") OrderCommissionStatisticsBO bo);
}
